package homework;

import java.sql.Connection;
import java.sql.DriverManager;

public class WorkDButil {

    public static Connection getConnection() throws Exception {
        Class.forName("com.mysql.cj.jdbc.Driver");
        Connection connection = DriverManager.getConnection(
                "jdbc:mysql://localhost:3306/book_managment?useUnicode=true&characterEncoding=utf8",
                "root",
                "root"
        );
        return connection;
    }
}
